package com.itheima.domain;

import java.util.List;

public class Person {

    private int id;
    private String name;
    private List<Person> list;

    public Person(int id, String name) {
        this.id = id;
        this.name = name;
    }

    public Person() {
    }

    public void test() {
        System.out.println("id:"+id);
        System.out.println("name:"+name);
        System.out.println("list:"+list.size());
    }

    public List<Person> getList() {
        return list;
    }

    public void setList(List<Person> list) {
        this.list = list;
    }

    public void setId(int id) {
        this.id = id;
    }

    public void setName(String name) {
        this.name = name;
    }
}
